﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<SDT.Site.ViewModels.ProductListModels>" %>
<%@ Import Namespace="SDT.Lib.Helpers" %>
<div class="pro-relate">
    <div class="caption">
        <h3><%=ViewData["Title"]%></h3>
    </div>
    <div>
        <ul>
            <%foreach (var item in Model.Products)
              { %>
            <li>
                <div class="title"><a href="/product/details/<%=item.ID %>/<%=Html.ToUrlFriendly(item.Title)%>"><%=Html.Encode(item.Title) %></a></div>
                <div class="content">
                    <%=Html.Encode(item.Summary.Length>150? item.Summary.Substring(0,150)+"...":item.Summary) %>
                </div> 
            </li>
            <%} %>
        </ul>
    </div>
</div>
